import React, { Component } from "react";

class Detail extends Component {
  constructor(props) {
    super(props);
    this.state = { id: '' };
  }
  render() {
    return <h2>详情--{this.state.id}</h2>;
  }
  componentDidMount() {
    let id = this.props.match.params.id
    this.setState({ id })
  }
}

export default Detail;
